package com.atguigu.tingshu.payment.service;

import com.atguigu.tingshu.model.order.OrderInfo;
import com.atguigu.tingshu.model.payment.PaymentInfo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.wechat.pay.java.service.payments.model.Transaction;

public interface PaymentInfoService extends IService<PaymentInfo> {

    /**
     * 保存交易记录
     * @param orderInfo
     * @param paymentType
     */
    void savePaymentInfo(OrderInfo orderInfo, String paymentType);

    /**
     * 更新交易状态记录。
     * @param transaction
     */
    void updatePaymentStatus(Transaction transaction);

    /**
     * 保存交易记录
     * @param orderNo
     * @param paymentType
     */
    void savePaymentInfo(String orderNo, String paymentType);
}
